package model

import "errors"

var ErrNotFound = errors.New("Rows selectd is zero")
var ErrNotUpdated = errors.New("Rows affected by update is zero")
var ErrNotDeleted = errors.New("Rows affected by delete is zero")

var IsConstraintError = errors.New("Constraint failed")
var IsValidationError = errors.New("Validation failed")
var IsNotSingular = errors.New("Name is not singular")

type AttachmentExtra struct {
	Meta        []*AttachmentMetum `json:"meta"`
	CategoryIds []int64            `json:"cids"`
	TagIds      []int64            `json:"tids"`
	DelTermIds  []uint64           `json:"delTids"`
	DelMetaIds  []uint64           `json:"delMids"`
}

type AttachmentRel struct {
	TermIds     []uint64           `json:"tids"`
	Meta        []*AttachmentMetum `json:"meta"`
	DelTermIds  []uint64           `json:"delTids"`
	DelMetumIds []uint64           `json:"delMids"`
}

type AttachmentTermRel struct {
	Meta        []*AttachmentTermMetum `json:"meta"`
	DelMetumIds []uint64               `json:"delMids"`
}
